﻿<!DOCTYPE html>

<html>
<!-- 加载：资源文件 css&js -->
<#include "../../include/resource.html">

<body class="full">          
		<#if msg?exists>
							<div id="msg24">
								<p class="ok"> ${msg} </p>
							</div>
						<#else>
							<#if errormsg?exists>
								<div id="msg25">
									<p class="error"> ${errormsg} </p>
								</div>
							</#if>
						</#if>   
             <div class="box">
                 <div class="ss-nav">温馨提示：*上传最大的图片为1M，上传的格式为：jpg、gif、.png、jepg、bmp</div>
                 
                 <form action="attestationNew.html" name="form1" method="post" enctype="multipart/form-data">
                 <ul>                            
                     <#if house??>
                     <li>
                         <div class="title-hh">房产：</div>
                         <div class="content-hh">                                       
                         	<#if house.province??>${house.province.name}</#if>-<#if house.city??>${house.city.name}</#if>-<#if house.area??>${house.area.name}</#if>-${house.address}
                         	<input type="hidden" name="houseId" value="${house.id!}" id="houseId"/>
                         </div>
                     </li>
                     </#if>
                      <#if car??>
                     <li>
                         <div class="title-hh">汽车：</div>
                         <div class="content-hh">                                      
                         	${car.brand}-${car.model}-${car.num}   
                         	<input type="hidden" name="carId" value="${car.id!}" id="carId"/>                                 	
                         </div>
                     </li>
                     </#if>
                     <li>
                         <div class="title-hh">资料类型：</div>
                         <div class="content-hh" >
                         	
                                                               
                             	<#if typeList?? && typeList?size gt 0>
                             	 <select class="test select-text"  name="typeId" id="typeId">
                             		<#list typeList  as item>
                             			<#if code?? && code=item.code>
                             			<option value="${item.id?c}" selected="selected">${item.name!''}</option>
                             			<#else>
                             			<option value="${item.id?c}">${item.name!''}</option>
                             			</#if>
                             		</#list>
                            		</select>
                            		
                             	</#if>
                         </div>
                     </li>
                 
                     <li>
                         <div class="title-hh">添加文件：</div>
                         <div class="content-hh">
                              <input type="file" name="litpic" class="input-text" id="litpic"/>
                              <a class="icon-up" id="litpicUploadBtn" href="javascript:;" >开始上传</a>        
                         	  <a class="icon-del" id="litpicCancleBtn" href="javascript:;" >全部取消</a>
								
                         </div>
                     </li>
                     <!--
                     <li>
                         <div class="title-hh">标题：</div>
                         <div class="content-hh">
                             <input type="text"  name="name" class="input-text">
                         </div>
                     </li>
                     <li>
                         <div class="title-hh">内容描述：</div>
                         <div class="content-hh">
                             <textarea cols="50" rows="5" class="input-text"></textarea>
                         </div>
                     </li>
                     <li>
                         <div class="title-hh">验证码：</div>
                         <div class="content-hh">
                             <input type="text" name="validcode" maxlength="5" class="input-text">
                             <img src="${webroot}/validimg.html" onClick="this.src='${webroot}/validimg.html?t=' + Math.random();" alt="点击刷新" class="verification-code">
                   </div>
               </li>
               <li>
               	<input type="hidden" name="type" value="1" />
               	<input type="hidden" name="code" value="${code!}" />
                   <input type="submit" class="input green-style confirm-post" value="确认提交">
                   <input type="hidden" name="actionType" value="attestation">
               </li>
                 -->
           </ul>
           </form>
       </div>
</div>
<script type="text/javascript" src="${webroot}${theme_dir}/js/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="${webroot}/plugins/uploadify/jquery.uploadify.js"></script>
<link rel="stylesheet" href="${webroot}/plugins/uploadify/uploadify.css" type="text/css" />
<script type="text/javascript" src="${webroot}${theme_dir}/js/uploadify.js"></script>
<script type="text/javascript">
	//var typeObj = $("#typeId option:selected");
   // $("#typeId").change(function(){
    	//typeObj = $("#typeId option:selected");
    	//$("body").Uploadify({id:"#litpic",cancleId:"#litpicCancleBtn",uploadId:"#litpicUploadBtn",carId:carId,houseId:houseId,typeId:$("#typeId option:selected"),height:25,width:100});
    //});	
	var carId;
	if($("#carId")){
		carId = $("#carId")
	}
	var houseId;
	if($("#houseId")){
		houseId = $("#houseId")
	}	
	$("body").Uploadify({id:"#litpic",cancleId:"#litpicCancleBtn",uploadId:"#litpicUploadBtn",carId:carId,houseId:houseId,typeId:$("#typeId option:selected"),height:30,width:100});
  
</script>

</body>
</html>

